<%-- 
    Document   : editcriteriaWork
    Created on : Jul 18, 2012, 3:53:33 PM
    Author     : VANANH
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">

<%@taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
<%@taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
<%@taglib prefix="rich" uri="http://richfaces.org/rich" %>
<%@taglib prefix="a4j" uri="http://richfaces.org/a4j" %>
<html>
    <head>
        <link rel="stylesheet" type="text/css" href="../css/popup.css"/>
        <link rel="stylesheet" type="text/css" href="../css/kapiform.css"/>
        <script type="text/javascript" language="javascript" src="../scripts/jQuery/jq.date.js"></script>  
        <link rel="stylesheet" type="text/css" href="../css/ui.datepicker.css"/>
        <script type="text/javascript" language="javascript" src="../scripts/jQuery/kapi.js"></script>
    </head>

    <script type="text/javascript">
        var open_cur = 0;
        $j = jQuery.noConflict();
        $j(document).ready(function(){             
            $j('input#dateN550').datepicker({ dateFormat: 'dd/mm/yy', showOn: 'button', buttonImage: '../images/calenda_icon.gif', buttonImageOnly: true }); 
            $j("#fancybox-close").live("click",function(){
                window.location= "setting.jsp?tab=header31&llinkC425";
            });
        });
    </script>

    <style type="text/css">
        #ui-datepicker-div
        {
            z-index: 9999999;
        }
        .form_item_content{
            float: left;
            margin-left: 10px;
            margin-top: 9px !important;
            width: 100%;
        }
        .blue{
            background-color: #E0EFFC;
        }
    </style>
    <f:view>
        <a4j:form>
            <body style=" float:left; width:auto; height:auto; margin:0px;">

                <a4j:status onstart="#{rich:component('statPane')}.show()" onstop="#{rich:component('statPane')}.hide()" />
                <f:loadBundle basename="#{environmentSession.localizationSource}" var="locale"/>

                <div class="popup" style="height:450px; width:500px">
                    <div class="popup-header">
                        <div class="title"><h:outputText value="KIỂM TRA CÔNG VIỆC"/></div>
                    </div>
                    <div class="popup-content">
                        <div class="main_content">
                            <div class="form_item_content" style="margin-top: 0px !important;" >
                                <h:inputHidden value="#{c350Controller.PC350}"/> <h:inputHidden value="#{c350Controller.CN351}"/>
                                <div class="item_content" style="display:block;float: left;">
                                    <div class="fields_input" >
                                        <label style="width: 80px !important;"><h:outputText value="Tên công việc: "/></label> 

                                        <h:selectOneMenu id="group" value="#{c350Controller.FC425}"  styleClass="cbx_editWork required"  valueChangeListener="#{c350Controller.actionSearchpopup}">
                                           <f:selectItem itemLabel="---------------------" itemValue="0"/>
                                            <f:selectItems value="#{c425Controller.cbbC425}" />

                                            <a4j:support event="onchange" reRender="listC3501"  />
                                        </h:selectOneMenu>

                                    </div>
                                    <div class="fields_input" style="width: 96%;">
                                        <label style="width: 80px !important;"><h:outputText value="KT công việc: "/></label> 

                                        <h:inputTextarea value="#{c350Controller.pvCV352}" style="height:30px; width:392px;"/> 

                                    </div>

                                    <div class="fields_input">
                                        <label style="text-align:right; width: 79px;"><h:outputText value="#{locale.description}"/> </label>
                                        <h:inputTextarea value="#{c350Controller.pvCV353}"  style="height:70px; width:394px;"  ></h:inputTextarea>

                                    </div>

                                </div>
                                <h:panelGroup id="listC3501">
                                    <div style="width: 96%;height: 50%;overflow: auto;float: left;margin-top: 5px;">
                                        <rich:dataTable rowClasses="white,blue" value="#{c350Controller.listC350}" var="item" rowKeyVar="row">
                                            <rich:column>
                                                <f:facet name="header">
                                                    <h:outputText value="STT"/>
                                                </f:facet>
                                                <div style="float: left;">
                                                    <h:outputText value="#{item.cn351}"/>
                                                </div>
                                            </rich:column>
                                            <rich:column>
                                                <f:facet name="header">
                                                    <h:outputText value="TÊN CÔNG VIỆC"/>
                                                </f:facet>
                                                <div style="float: left;">
                                                    <h:outputText value="#{item.cv427}"/>
                                                </div>
                                            </rich:column>
                                            <rich:column>
                                                <f:facet name="header">
                                                    <h:outputText value="DANH SÁCH KT"/>
                                                </f:facet>
                                                <div style="float: left;">
                                                    <h:outputText value="#{item.cv352}"/>
                                                </div>
                                            </rich:column>
                                        </rich:dataTable>
                                    </div>
                                </h:panelGroup>

                            </div>
                        </div>

                    </div>

                    <div class="popup-footer">

                        <h:commandButton   action="#{c350Controller.stdc_tools_inserttabc4251}" value="#{locale.close}" styleClass="buttonsave">

                        </h:commandButton>
                        <a4j:commandButton reRender="listC3501" actionListener="#{c350Controller.stdc_tools_inserttabc425}" value="#{locale.save}" styleClass="buttonsave">

                        </a4j:commandButton>

                        <h:inputHidden value="#{c350Controller.PC350}" id="PC350"/>

                    </div>

                </div>
                <rich:modalPanel styleClass="pleaseimage" id="statPane" autosized="true" minHeight="10" minWidth="80"
                                 height="10" width="80" zindex="2000">
                    <h:graphicImage value="/images/loadingAnimation.gif" alt="ai" />
                </rich:modalPanel>

            </body>
        </a4j:form>
    </f:view>
</html>
<script type="text/javascript">
    $j(document).ready(function(){
        yhight = ($j('.popup').height()-90)+"px" ;
        $j('.main_content').css('height',yhight );
        $j('.popup-content').css('height',yhight );
    });
</script>